#include "../../Header/Game/fwState.h"

State::State()
:m_iCount(0)
{

}

State::~State()
{

}

void State::Destroy()
{
	for (int i = 0; i < m_iCount; i++)
	{
		Entity * temp = m_lEntities.at(i);
		temp->Destroy();
		SAFE_DEL(temp);
	}
	m_lEntities.clear();
}

void State::Update(float deltaTime)
{
	for (int i = 0; i < m_iCount; i++)
	{
		m_lEntities.at(i)->Update(deltaTime);
	}
}

void State::Draw()
{
	for (int i = 0; i < m_iCount; i++)
	{
		m_lEntities.at(i)->Draw();
	}
}

void State::Key(const char key, bool status)
{

}

void State::Touch(float x, float y, bool status)
{

}